<template>
  <div>
    子组件
    {{text}}
    {{ msg }}
    <button @click="changeMsg">点我切换</button>
  </div>
</template>

<script>
export default {
    props:["text","msg"],
    methods:{
        changeMsg(){
            this.$emit("changeText","戴予蓝")
        }
    }

}
</script>

<style>

</style>